package com.platform.core.entity;

import com.platform.comm.entity.IdEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Table;

/**
 * Description: 用户角色关联实体类
 *
 * @author libin
 * Created on 2019/4/18
 **/
@EqualsAndHashCode(callSuper = true)
@Data
@Entity
@Table(name = "ncloud_sys_user_role")
public class SysUserRole extends IdEntity {

    private static final long serialVersionUID = -7233191026370789321L;

    @Column(name = "user_id", length = 36)
    private String userId;

    @Column(name = "role_id", length = 36)
    private String roleId;

    /**
     * 管理组织
     */
    @Column(name = "manage_domain", length = 150)
    private String manageDomain;

    /**
     * 是否访问下级组织
     */
    @Column(name = "access_sub_org", length = 2)
    private String accessSubOrg;

    @Column(name = "role_code", length = 200)
    private String roleCode;
}
